# -*- coding: utf-8 -*-
import ho.pisa as pisa

def helloWorld():
    filename = __file__ + ".pdf"
    pdf = pisa.CreatePDF(
        u"Hello <strong>World</strong> <img src='' alt='310420120549193168' />",
        file(filename, "wb"),
        show_error_as_pdf=True,
        )
    if not pdf.err:
        pisa.startViewer(filename)

if __name__=="__main__":
    pisa.showLogging()
    helloWorld()
